nestedsvm: reduce TLB flushes
authorKeir Fraser <keir@xen.org>
Fri, 20 May 2011 08:06:58 +0000 (09:06 +0100)
committerKeir Fraser <keir@xen.org>
Fri, 20 May 2011 08:06:58 +0000 (09:06 +0100)
commit2be3bcbfe84713c49a42041baf3451e20a381355
treee2412be6beacd41de1587d24422050bad7df67b1
parent89ed067cfd2c86fcaac3dedd55d3fab785f82e94
nestedsvm: reduce TLB flushes

Reduce TLB flushes:
1. When we update the cr3 during VMRUN/VMEXIT emulation
    we toggle between n1asid and n2asid forth and back
    => no TLB flush needed
2. Only flush n1asid or n2asid depending on vcpu guest mode
    and not both unconditionally.

Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
Signed-off-by: Keir Fraser <keir@xen.org>
xen/arch/x86/hvm/svm/svm.c